﻿Public Class Chart
    Public tag As String
    Public user As String
    Public from_ As String
    Public to_ As String

    Public Sub New(ByRef xmlChart As XElement)
        parseXML(xmlChart)
    End Sub

    Public Sub parseXML(ByRef xmlChart As XElement)
        If xmlChart.HasAttributes() Then

        End If

        If (xmlChart.<lfm>.<weeklychartlist>.Attributes("tag").Count > 0) Then
            tag = xmlChart.<lfm>.<weeklychartlist>.Attributes("tag").First
        End If
        If (xmlChart.<lfm>.<weeklychartlist>.Attributes("user").Count > 0) Then
            tag = xmlChart.<lfm>.<weeklychartlist>.Attributes("user").First
        End If
        If (xmlChart.<lfm>.<weeklychartlist>.<chart>.Attributes("from").Count > 0) Then
            from_ = xmlChart.<lfm>.<weeklychartlist>.<chart>.Attributes("from").First
        End If
        If (xmlChart.<lfm>.<weeklychartlist>.<chart>.Attributes("from").Count > 0) Then
            to_ = xmlChart.<lfm>.<weeklychartlist>.<chart>.Attributes("from").First
        End If
    End Sub

End Class
